package config

import "github.com/spf13/viper"

type Config struct {
	Mysql
	Redis
}

type Mysql struct {
	Host     string
	Pose     int
	User     string
	Password string
	DB       string
}

type Redis struct {
	Addr     string
	Password string
	DB       int
}

var Conf Config

func Init() {
	viper.SetConfigFile("../../config/dev.yaml")
	viper.ReadInConfig()
	viper.Unmarshal(&Conf)
}
